package com.zsrt.oa.user.service.impl;

import com.zsrt.oa.user.dao.IUserDao;
import com.zsrt.oa.user.dao.impl.UserDaoImpl;
import com.zsrt.oa.user.entity.UserEntity;
import com.zsrt.oa.user.service.IUserService;

public class UserServiceImpl implements IUserService {
	private IUserDao dao = new UserDaoImpl();
	
	@Override
	public void add(UserEntity entity) throws Exception {
		dao.add(entity);
	}

	@Override
	public void del(UserEntity entity) throws Exception {
		dao.del(entity);
	}

	@Override
	public int update(UserEntity search, UserEntity newEntity) throws Exception {
		return dao.update(search, newEntity);
	}

	@Override
	public UserEntity query(Integer id) throws Exception {
		return dao.query(id);
	}

}
